<?php $this->beginContent('application.views.layouts.main'); ?>
	<div class="container" style="width:100%">
		<div id="sidebar" style="width:30%;float:right;">
			<div align="center" style="border:1px solid #C9E0ED;border-radius:8px;padding:10px;">
				<div>
					<?php
						$credentials = Yii::app()->db->createCommand()
						->select('glogin, gpassword')
						->from('tbl_users')
						->where('username=:username', array(':username'=>Yii::app()->user->name))
						->queryRow();
						
						if (Yii::app()->user->name == 'admin') {
							Yii::app()->CALENDAR->doEvents("list", null, $credentials["glogin"], $credentials["gpassword"]); 
						} 
						else {
							Yii::app()->CALENDAR->doEvents("list", null, "elcp.promo", "elcppromo@1"); 
						}
						//echo CHtml::link("test", "#", array('onclick'=>'$.fn.myFunction(); return false;')); */
					?>
				</div>
			</div>
		</div>
		
		<div id="content" style="width:66%;float:left;">
			<div style="border:1px solid #C9E0ED;border-radius:8px;padding:10px;">
				<?php echo $content; ?>
			</div>
		</div>

		<br/>
		
		<!--<table align="center" style="width:100%;">
			<tr>
			<td>
			<div align="center" style="border:1px solid #C9E0ED;border-radius:8px;">
				<div><a href="http://www.russianelectronics.ru" target="_blank">www.russianelectronics.ru</a></div>
				<?php /*
				$config=Yii::app()->basePath . '/extensions/gapi/gapi.php';
				require($config);
				$ga = '';
				$ga = new gapi('google@elcp.ru','UeuktCnfnTKCG');
				$ga->requestReportData(5747412,array('browser','browserVersion'),array('pageviews','visits'));
				
				$rpv = $ga->getPageviews();
				$rtv = $ga->getVisits();
				
				$this->widget('application.widgets.rgraph.RGraphBar', array(
					'data' => array(array($rpv, $rtv)),
					'options' => array(
						'chart' => array(
							'colors' => array('#2A17B1', '#98ED00'),
							'labels' => array('Pageviews', 'Visits'),
							'numyticks' => 5,
							'variant' => '3d',
							'strokestyle' => 'transparent',
							'hmargin' => array('grouped' => 0,),
							'ylabels' => array('count' => 5,),
							'gutter' => array('left' => 35,),
							'scale' => array('round' => true,),
						)
					)
				));*/
				?>
			</div>
			</td>
			<td>
			<div align="center" style="border:1px solid #C9E0ED;border-radius:8px;">
				<div><a href="http://www.lightingmedia.ru" target="_blank">www.lightingmedia.ru</a></div>
				<?php /*
				$ga = '';
				$ga = new gapi('google@elcp.ru','UeuktCnfnTKCG');
				$ga->requestReportData(23265676,array('browser','browserVersion'),array('pageviews','visits'));
				
				$lpv = $ga->getPageviews();
				$ltv = $ga->getVisits();
				
				$this->widget('application.widgets.rgraph.RGraphBar', array(
					'data' => array(array($lpv, $ltv)),
					'options' => array(
						'chart' => array(
							'colors' => array('#2A17B1', '#98ED00'),
							'labels' => array('Pageviews', 'Visits'),
							'numyticks' => 5,
							'variant' => '3d',
							'strokestyle' => 'transparent',
							'hmargin' => array('grouped' => 0,),
							'ylabels' => array('count' => 5,),
							'gutter' => array('left' => 35,),
							'scale' => array('round' => true,),
						)
					)
				)); */
				?>
			</div>
			</td>
			<td>
			<div align="center" style="border:1px solid #C9E0ED;border-radius:8px;">
				<div><a href="http://www.elcomdesign.ru" target="_blank">www.elcomdesign.ru</a></div>
				<?php /*
				$ga = '';
				$ga = new gapi('google@elcp.ru','UeuktCnfnTKCG');
				$ga->requestReportData(23307667,array('browser','browserVersion'),array('pageviews','visits'));
				
				$epv = $ga->getPageviews();
				$etv = $ga->getVisits();
				
				$this->widget('application.widgets.rgraph.RGraphBar', array(
					'data' => array(array($epv, $etv)),
					'options' => array(
						'chart' => array(
							'colors' => array('#2A17B1', '#98ED00'),
							'labels' => array('Pageviews', 'Visits'),
							'numyticks' => 5,
							'variant' => '3d',
							'strokestyle' => 'transparent',
							'hmargin' => array('grouped' => 0,),
							'ylabels' => array('count' => 5,),
							'gutter' => array('left' => 35,),
							'scale' => array('round' => true,),
						)
					)
				)); */
				?>
			</div>
			</td>
			</tr>
		</table>-->
	</div>
<?php $this->endContent(); ?>